package com.hxzy.projectssmplus.entity;

import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;

/**
 * house_new
 * @author 
 */
@TableName(value = "house_new")
public class HouseNew implements Serializable {

    @TableId(value = "id",type = IdType.AUTO)
    private Long id;

    /**
     * 新房名称
     */

    private String name;

    /**
     * 新房别名
     */
    private String alias;

    /**
     * 房屋状态 sys_dict_data表
     */
    @NotBlank(message = "房屋状态不能为空")
    private String statusId;

    /**
     * 房屋类型 sys_dict_data表
     */
    @NotBlank(message = "房屋类型不能为空")
    private String typesId;

    /**
     * 排序，值越大排在越前面
     */
    private Integer orderNum;

    /**
     * 房屋均价
     */
    private Integer avgPrice;

    /**
     * 房屋均价  sys_dict_data表
     */
    private String avgUnit;

    /**
     * 房屋总价
     */
    private Integer totalPrice;

    /**
     * 房屋总价  sys_dict_data表 单位（万/套）
     */
    private String totalUnit;

    /**
     * 房屋项目地址
     */
    @NotBlank(message = "房屋项目地址不能为空")
    private String address;

    /**
     * 售楼处地址
     */
    private String salesAddress;

    /**
     * 开发商
     */
    private String developers;

    /**
     * 楼盘特色
     */
    private String feature;

    /**
     * 最新开盘
     */
    @JSONField(format = "yyyy-MM-dd")
    private Date openTime;

    /**
     * 经度
     */
    @NotNull(message = "经度不能为空")
    private BigDecimal longitude;

    /**
     * 纬度
     */
    @NotNull(message = "纬度不能为空")
    private BigDecimal latitude;

    /**
     * 县编号 对sys_area
     */
    @NotNull(message = "县编号不能为空")
    private Long pid;

    /**
     * 市编号 对sys_area
     */
    @NotNull(message = "市编号不能为空")
    private Long cid;

    /**
     * 区编号 对sys_area
     */
    @NotNull(message = "区编号不能为空")
    private Long aid;

    /**
     * 咨询电话
     */
    @NotBlank(message = "咨询电话不能为空")
    private String mobile;

    /**
     * 审核状态 sys_dict_data表（0 未审核 1已审核）
     */
    private String aduitState;

    /**
     * 审核创建时间
     */
    @JSONField(format = "yyyy-MM-dd")
    private Date aduitTime;

    /**
     * 审核人
     */
    private String aduitBy;

    /**
     * 创建人
     */
    private String createBy;

    /**
     * 创建时间
     */
    @JSONField(format = "yyyy-MM-dd")
    private Date createTime;

    /**
     * 修改人
     */
    private String updateBy;

    /**
     * 修改时间
     */
    @JSONField(format = "yyyy-MM-dd")
    private Date updateTime;

    private static final long serialVersionUID = 1L;

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getAlias() {
        return alias;
    }

    public void setAlias(String alias) {
        this.alias = alias;
    }

    public String getStatusId() {
        return statusId;
    }

    public void setStatusId(String statusId) {
        this.statusId = statusId;
    }

    public String getTypesId() {
        return typesId;
    }

    public void setTypesId(String typesId) {
        this.typesId = typesId;
    }

    public Integer getOrderNum() {
        return orderNum;
    }

    public void setOrderNum(Integer orderNum) {
        this.orderNum = orderNum;
    }

    public Integer getAvgPrice() {
        return avgPrice;
    }

    public void setAvgPrice(Integer avgPrice) {
        this.avgPrice = avgPrice;
    }

    public String getAvgUnit() {
        return avgUnit;
    }

    public void setAvgUnit(String avgUnit) {
        this.avgUnit = avgUnit;
    }

    public Integer getTotalPrice() {
        return totalPrice;
    }

    public void setTotalPrice(Integer totalPrice) {
        this.totalPrice = totalPrice;
    }

    public String getTotalUnit() {
        return totalUnit;
    }

    public void setTotalUnit(String totalUnit) {
        this.totalUnit = totalUnit;
    }

    public String getAddress() {
        return address;
    }

    public void setAddress(String address) {
        this.address = address;
    }

    public String getSalesAddress() {
        return salesAddress;
    }

    public void setSalesAddress(String salesAddress) {
        this.salesAddress = salesAddress;
    }

    public String getDevelopers() {
        return developers;
    }

    public void setDevelopers(String developers) {
        this.developers = developers;
    }

    public String getFeature() {
        return feature;
    }

    public void setFeature(String feature) {
        this.feature = feature;
    }

    public Date getOpenTime() {
        return openTime;
    }

    public void setOpenTime(Date openTime) {
        this.openTime = openTime;
    }

    public BigDecimal getLongitude() {
        return longitude;
    }

    public void setLongitude(BigDecimal longitude) {
        this.longitude = longitude;
    }

    public BigDecimal getLatitude() {
        return latitude;
    }

    public void setLatitude(BigDecimal latitude) {
        this.latitude = latitude;
    }

    public Long getPid() {
        return pid;
    }

    public void setPid(Long pid) {
        this.pid = pid;
    }

    public Long getCid() {
        return cid;
    }

    public void setCid(Long cid) {
        this.cid = cid;
    }

    public Long getAid() {
        return aid;
    }

    public void setAid(Long aid) {
        this.aid = aid;
    }

    public String getMobile() {
        return mobile;
    }

    public void setMobile(String mobile) {
        this.mobile = mobile;
    }

    public String getAduitState() {
        return aduitState;
    }

    public void setAduitState(String aduitState) {
        this.aduitState = aduitState;
    }

    public Date getAduitTime() {
        return aduitTime;
    }

    public void setAduitTime(Date aduitTime) {
        this.aduitTime = aduitTime;
    }

    public String getAduitBy() {
        return aduitBy;
    }

    public void setAduitBy(String aduitBy) {
        this.aduitBy = aduitBy;
    }

    public String getCreateBy() {
        return createBy;
    }

    public void setCreateBy(String createBy) {
        this.createBy = createBy;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public String getUpdateBy() {
        return updateBy;
    }

    public void setUpdateBy(String updateBy) {
        this.updateBy = updateBy;
    }

    public Date getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        HouseNew other = (HouseNew) that;
        return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
            && (this.getName() == null ? other.getName() == null : this.getName().equals(other.getName()))
            && (this.getAlias() == null ? other.getAlias() == null : this.getAlias().equals(other.getAlias()))
            && (this.getStatusId() == null ? other.getStatusId() == null : this.getStatusId().equals(other.getStatusId()))
            && (this.getTypesId() == null ? other.getTypesId() == null : this.getTypesId().equals(other.getTypesId()))
            && (this.getOrderNum() == null ? other.getOrderNum() == null : this.getOrderNum().equals(other.getOrderNum()))
            && (this.getAvgPrice() == null ? other.getAvgPrice() == null : this.getAvgPrice().equals(other.getAvgPrice()))
            && (this.getAvgUnit() == null ? other.getAvgUnit() == null : this.getAvgUnit().equals(other.getAvgUnit()))
            && (this.getTotalPrice() == null ? other.getTotalPrice() == null : this.getTotalPrice().equals(other.getTotalPrice()))
            && (this.getTotalUnit() == null ? other.getTotalUnit() == null : this.getTotalUnit().equals(other.getTotalUnit()))
            && (this.getAddress() == null ? other.getAddress() == null : this.getAddress().equals(other.getAddress()))
            && (this.getSalesAddress() == null ? other.getSalesAddress() == null : this.getSalesAddress().equals(other.getSalesAddress()))
            && (this.getDevelopers() == null ? other.getDevelopers() == null : this.getDevelopers().equals(other.getDevelopers()))
            && (this.getFeature() == null ? other.getFeature() == null : this.getFeature().equals(other.getFeature()))
            && (this.getOpenTime() == null ? other.getOpenTime() == null : this.getOpenTime().equals(other.getOpenTime()))
            && (this.getLongitude() == null ? other.getLongitude() == null : this.getLongitude().equals(other.getLongitude()))
            && (this.getLatitude() == null ? other.getLatitude() == null : this.getLatitude().equals(other.getLatitude()))
            && (this.getPid() == null ? other.getPid() == null : this.getPid().equals(other.getPid()))
            && (this.getCid() == null ? other.getCid() == null : this.getCid().equals(other.getCid()))
            && (this.getAid() == null ? other.getAid() == null : this.getAid().equals(other.getAid()))
            && (this.getMobile() == null ? other.getMobile() == null : this.getMobile().equals(other.getMobile()))
            && (this.getAduitState() == null ? other.getAduitState() == null : this.getAduitState().equals(other.getAduitState()))
            && (this.getAduitTime() == null ? other.getAduitTime() == null : this.getAduitTime().equals(other.getAduitTime()))
            && (this.getAduitBy() == null ? other.getAduitBy() == null : this.getAduitBy().equals(other.getAduitBy()))
            && (this.getCreateBy() == null ? other.getCreateBy() == null : this.getCreateBy().equals(other.getCreateBy()))
            && (this.getCreateTime() == null ? other.getCreateTime() == null : this.getCreateTime().equals(other.getCreateTime()))
            && (this.getUpdateBy() == null ? other.getUpdateBy() == null : this.getUpdateBy().equals(other.getUpdateBy()))
            && (this.getUpdateTime() == null ? other.getUpdateTime() == null : this.getUpdateTime().equals(other.getUpdateTime()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
        result = prime * result + ((getName() == null) ? 0 : getName().hashCode());
        result = prime * result + ((getAlias() == null) ? 0 : getAlias().hashCode());
        result = prime * result + ((getStatusId() == null) ? 0 : getStatusId().hashCode());
        result = prime * result + ((getTypesId() == null) ? 0 : getTypesId().hashCode());
        result = prime * result + ((getOrderNum() == null) ? 0 : getOrderNum().hashCode());
        result = prime * result + ((getAvgPrice() == null) ? 0 : getAvgPrice().hashCode());
        result = prime * result + ((getAvgUnit() == null) ? 0 : getAvgUnit().hashCode());
        result = prime * result + ((getTotalPrice() == null) ? 0 : getTotalPrice().hashCode());
        result = prime * result + ((getTotalUnit() == null) ? 0 : getTotalUnit().hashCode());
        result = prime * result + ((getAddress() == null) ? 0 : getAddress().hashCode());
        result = prime * result + ((getSalesAddress() == null) ? 0 : getSalesAddress().hashCode());
        result = prime * result + ((getDevelopers() == null) ? 0 : getDevelopers().hashCode());
        result = prime * result + ((getFeature() == null) ? 0 : getFeature().hashCode());
        result = prime * result + ((getOpenTime() == null) ? 0 : getOpenTime().hashCode());
        result = prime * result + ((getLongitude() == null) ? 0 : getLongitude().hashCode());
        result = prime * result + ((getLatitude() == null) ? 0 : getLatitude().hashCode());
        result = prime * result + ((getPid() == null) ? 0 : getPid().hashCode());
        result = prime * result + ((getCid() == null) ? 0 : getCid().hashCode());
        result = prime * result + ((getAid() == null) ? 0 : getAid().hashCode());
        result = prime * result + ((getMobile() == null) ? 0 : getMobile().hashCode());
        result = prime * result + ((getAduitState() == null) ? 0 : getAduitState().hashCode());
        result = prime * result + ((getAduitTime() == null) ? 0 : getAduitTime().hashCode());
        result = prime * result + ((getAduitBy() == null) ? 0 : getAduitBy().hashCode());
        result = prime * result + ((getCreateBy() == null) ? 0 : getCreateBy().hashCode());
        result = prime * result + ((getCreateTime() == null) ? 0 : getCreateTime().hashCode());
        result = prime * result + ((getUpdateBy() == null) ? 0 : getUpdateBy().hashCode());
        result = prime * result + ((getUpdateTime() == null) ? 0 : getUpdateTime().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", id=").append(id);
        sb.append(", name=").append(name);
        sb.append(", alias=").append(alias);
        sb.append(", statusId=").append(statusId);
        sb.append(", typesId=").append(typesId);
        sb.append(", orderNum=").append(orderNum);
        sb.append(", avgPrice=").append(avgPrice);
        sb.append(", avgUnit=").append(avgUnit);
        sb.append(", totalPrice=").append(totalPrice);
        sb.append(", totalUnit=").append(totalUnit);
        sb.append(", address=").append(address);
        sb.append(", salesAddress=").append(salesAddress);
        sb.append(", developers=").append(developers);
        sb.append(", feature=").append(feature);
        sb.append(", openTime=").append(openTime);
        sb.append(", longitude=").append(longitude);
        sb.append(", latitude=").append(latitude);
        sb.append(", pid=").append(pid);
        sb.append(", cid=").append(cid);
        sb.append(", aid=").append(aid);
        sb.append(", mobile=").append(mobile);
        sb.append(", aduitState=").append(aduitState);
        sb.append(", aduitTime=").append(aduitTime);
        sb.append(", aduitBy=").append(aduitBy);
        sb.append(", createBy=").append(createBy);
        sb.append(", createTime=").append(createTime);
        sb.append(", updateBy=").append(updateBy);
        sb.append(", updateTime=").append(updateTime);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}